﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using DataComminucation;
using ConfigurationFactory;
using Picking.Common;

namespace PickingBusiness
{
    public abstract class Configuration
    {
        public static DataRow GetCurrentUseParameters(string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.GetInUseParameters(lineCode);
        }

        public static DataTable GetConfigSetup(string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.GetConfigSetup(lineCode);
        }

        public static bool SaveConfigSetup(DataTable table, string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.SaveConfigSetup(table, lineCode);
        }

        public static WorkersAndLightsSetupModel GetWorkersAndLightsSetup(string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.GetWorkersAndLightsSetup(lineCode);
        }

        public static bool SaveWorkersAndLightsSetup(WorkersAndLightsSetupModel model, string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.SaveWorkersAndLightsSetup(model, lineCode);
        }

        public static LightAndDNoSetupModel GetLightAndDNoSetup(string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.GetLightAndDNoSetup(lineCode);
        }

        public static bool SaveLightAndDNoSetup(LightAndDNoSetupModel model, string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.SaveLightAndDNoSetup(model, lineCode);
        }

        public static SebangoAndDNoSetupModel GetSebangoAndDNoSetup(string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.GetSebangoAndDNoSetup(lineCode);
        }

        public static bool SaveSebangoAndDNoSetup(SebangoAndDNoSetupModel model, string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.SaveSebangoAndDNoSetup(model, lineCode);
        }

        public static SebangoAndProductBookModel GetSebangoAndProductBook(string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.GetSebangoAndProductBook(lineCode);
        }

        public static bool SaveSebangoAndProductBook(SebangoAndProductBookModel model, string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.SaveSebangoAndProductBook(model, lineCode);
        }

        public static string GetLineCode(string lineCode)
        {
            IParametersSetupDataAccess dataAccess = DataComminucationFactory.GetParametersSetupDataAccess();
            return dataAccess.GetLineCode(lineCode);
        }
    }
}
